<jsp:include page="logincheck.jsp" />
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %>
<%@ page import="java.util.*" %>

<jsp:useBean id="editPhoneAccount" class="se2.PhoneAccount" scope="request"/>
<jsp:setProperty name="editPhoneAccount" property="*"/>

<jsp:useBean id="billingPlans" class="se2.BillingPlan" scope="request"/>
<jsp:setProperty name="billingPlans" property="*"/>

<jsp:useBean id="bill" class="se2.Bill" scope="request"/>
<jsp:setProperty name="bill" property="*"/>

<html>

	<head>
		<title>Administration Console</title>
		<link rel="stylesheet" href="default.css" type="text/css" media="screen"></link>
		<script type="text/javascript" language="javascript" src="addPhoneAccount.js"></script>
	</head>

	<body>
		<div id="container">
			<div id="navigation">
<p>&nbsp;</p>
<jsp:include page="navigation.jsp" />
			</div>
			
			<div id="header">				
				<img src="images/header.png" />
			</div>

			<div id="content">
<!-- Main code -->

<!-- Save Phone Account id temporarily -->
<!--<input type="hidden" name="paid" value="<%= request.getParameter("id")%>" />-->

<h1>Phone Account :: Add Phone Bill</h1>

	<%
		bill.setPhoneAccount(Integer.parseInt(request.getParameter("id")));
	%>

<form name="addBill" id="addBill" method="post" action="chargeBill.jsp?id=<%= request.getParameter("id")%>&cid=<%= request.getParameter("cid")%>" onSubmit="return validate(this);">
	
	<input type="hidden" id="starttime" name="starttime" value="<%= bill.getFormattedGenStart() %>" />
	<input type="hidden" id="endtime" name="endtime" value="<%= bill.getFormattedGenEnd() %>" />
	
	<table border="0" cellpadding="0" cellspacing="0" width="100%">
							
		<tr>
			<td colspan="2" align="right">
				<input type="submit" value="Generate" />
				<input type="button" value="Cancel" onclick="javascript:document.location.href='viewBill.jsp?id=<%= request.getParameter("id") %>&cid=<%= request.getParameter("cid") %>'" />
			</td>
		</tr>
	</table>
</form>

<!-- Main Code -->
			</div>

			<div id="footer">
<jsp:include page="footer.jsp" />
			</div>
		</div>
	</body>

</html>